sanitize
This method sanitizes the given intent. If dirty members are found, the errors are consumed by the penalty object. The penalty action could be called multiple times if multiple issues exist.
Return
a sanitized copy of the given intent.
Parameters
in
the given intent.
penalty
consumer of the error message if dirty members are found.